<%@page contentType="text/html;charset=UTF-8"%>
<%@page pageEncoding="UTF-8"%>
<%@ page session="false" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <title>Modify Order</title>
<c:import url="/WEB-INF/formating/link.jsp"/>
    </head>
    <body>
        <c:import url="/WEB-INF/formating/menu.jsp"/>
        <div id="conteiner">
            <c:import url="/WEB-INF/formating/sideMenu.jsp"/>
            <div id="main">
                <h1>
		Modify Order
                </h1>

                <form:form modelAttribute="boxOrder" action="/orderMod" method="post">
                    <fieldset>
                        <legend>Modify Order</legend>
                        <p>
                            <form:hidden path="boxOrderID" />
                        </p>
                        <p>
                            <form:label for="customer" path="customer" cssErrorClass="error">customer</form:label><br/>
                            <form:select path="customer" multiple="false">
                                <form:options items="${customerList}"/>
                            </form:select>
                            <form:errors path="customer" />
                        </p>
                        <p>
                            <form:label for="dateOrdered" path="dateOrdered" cssErrorClass="error">dateOrdered</form:label><br/>
                            <form:input path="dateOrdered" /> <form:errors path="dateOrdered"/>
                        </p>
                        <p>
                            <form:label for="realised" path="realised" cssErrorClass="error">realised</form:label><br/>
                            <form:select path="realised">
                                <form:option value="true" label="true"/>
                                <form:option value="false" label="false"/>
                            </form:select>
                            <form:errors path="realised" />
                        </p>
                        <p>
                            <form:label for="totalPrice" path="totalPrice">totalPrice</form:label><br/>
                            <form:input path="totalPrice" /> <form:errors path="totalPrice"/>
                        </p>
                        <p>
                            <form:label for="boxes" path="boxes" cssErrorClass="error">boxes</form:label><br/>
                            <form:select path="boxes" multiple="true">
                                <form:options items="${boxList}" />
                            </form:select>
                            <form:errors path="boxes" />
                        </p>
                        <p>
                            <input type="submit" name="Save"/>
                        </p>
                    </fieldset>
                </form:form>

                <hr>

                <ul>
                    <li><a href="order">Back to Order</a></li>
                </ul>
            </div>
        </div>
        <c:import url="/WEB-INF/formating/foot.jsp"/>
    </body>
</html>